package com.tfleo.mealssenger.object;

import com.tfleo.mealssenger.Main;

public class Food {
	public static final String IMAGE_PATH = Main.SERVER_URL + "img/food/";
	
	public final int id;
	public final String name;
	public final int locationId;
	public final String locationName;
	public final String description;
	public final String imageUrl;
	public final String category;
	public final String tag;
	public final int numEaten;
	public final float rating;

	/**
	 * Constructor of Food instance
	 * 
	 * @param id
	 * @param name
	 * @param locationId
	 * @param locationName
	 * @param description
	 * @param image
	 * @param category
	 * @param tag
	 * @param numEaten
	 * @param rating
	 */
	public Food(int id, String name, int locationId, String locationName, String description, 
			String image, String category, String tag, int numEaten, float rating) {
		this.id = id;
		this.name = name;
		this.locationId = locationId;
		this.locationName = locationName;
		this.description = description;
		this.imageUrl = IMAGE_PATH + image;
		this.category = category;
		this.tag = tag;
		this.numEaten = numEaten;
		this.rating = rating;
	}
	
	/**
	 * Constructor of Food instance in FoodGalleryActivity (not in used)
	 * 
	 * @param id
	 * @param name
	 * @param locationName
	 * @param description
	 * @param image
	 */
	public Food(int id, String name, int locationId, String locationName, String description, String image) {
		this.id = id;
		this.name = name;
		this.locationId = locationId;
		this.locationName = locationName;
		this.description = description;
		this.imageUrl = IMAGE_PATH + image;
		this.category = null;
		this.tag = "";
		this.numEaten = 0;
		this.rating = 0;
	}
}
